class PddListModelEntity {
  List<PddListModelData> data;
  int code;
  String msg;

  PddListModelEntity({this.data, this.code, this.msg});

  PddListModelEntity.fromJson(Map<String, dynamic> json) {
    if (json['data'] != null) {
      data = new List<PddListModelData>();
      (json['data']['list'] as List).forEach((v) {
        data.add(new PddListModelData.fromJson(v));
      });
    }
    code = json['code'];
    msg = json['msg'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    if (this.data != null) {
      data['data']['list'] = this.data.map((v) => v.toJson()).toList();
    }
    data['code'] = this.code;
    data['msg'] = this.msg;
    return data;
  }
}

class PddListModelData {
  var goods_id; //	商品id
  String cat_id; //	商品分类ID
  String goods_name; //	商品编码/订货号
  String goods_code; //	商品编码
  String img; //商品图片/主图/封面图
  String tmp_img; //	商品图片缩虐图
  String video; //商品介绍视频（本地）
  String video_url; //	商品介绍视频地址（第三方）
  String description; //简介
  String brand_id; //	品牌ID
  String clicknum; //	浏览量
  String old_price; //	参考价
  String price; //实际价格
  String inventory; //	库存
  String sales_volume; //	销量
  String create_time; //	创建时间

  PddListModelData({
  this.goods_id,//  商品id
this.cat_id,// 商品分类ID
this.goods_name,// 商品编码/订货号
this.goods_code,// 商品编码
this.img,//商品图片/主图/封面图
this.tmp_img,//  商品图片缩虐图
this.video,//商品介绍视频（本地）
this.video_url,//  商品介绍视频地址（第三方）
this.description,//简介
this.brand_id,// 品牌ID
this.clicknum,// 浏览量
this.old_price,//  参考价
this.price,//实际价格
this.inventory,//  库存
this.sales_volume,// 销量
this.create_time,
  });

  PddListModelData.fromJson(Map<String, dynamic> json) {
    goods_id = json['goods_id'];
    goods_name = json['goods_name'];
    cat_id = json['cat_id'].toString();
    goods_code = json['goods_code'];
    img = json['img'];
    tmp_img = json['tmp_img'];
    video = json['video'];
    video_url = json['video_url'];
    description = json['description'];
    brand_id = json['brand_id'].toString();
    clicknum = json['clicknum'].toString();
    old_price = json['old_price'];
    price = json['price'];
    inventory = json['inventory'].toString();
    sales_volume = json['sales_volume'].toString();
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['goods_id'] = this.goods_id;
    data['goods_name'] = this.goods_name;
    data['cat_id'] = this.cat_id;
    data['goods_code'] = this.goods_code;
    data['img'] = this.img;
    data['tmp_img'] = this.tmp_img;
    data['video'] = this.video;
    data['video_url'] = this.video_url;
    data['description'] = this.description;
    data['brand_id'] = this.brand_id;
    data['clicknum'] = this.clicknum;
    data['old_price'] = this.old_price;
    data['price'] = this.price;
    data['inventory'] = this.inventory;
    data['sales_volume'] = this.sales_volume;
    return data;
  }
}
